package cn.fangline.base.enums;

/**
 * Created by 抽离 on 2017/5/16 0016.
 */
public enum CommentType {

    CommentNice(1, "喜欢你的"),CommentBad(2, "不喜欢你的");

    public Integer getCommentType() {
        return commentType;
    }

    public void setCommentType(Integer commentType) {
        this.commentType = commentType;
    }

    public String getCommentString() {
        return commentString;
    }

    public void setCommentString(String commentString) {
        this.commentString = commentString;
    }


    private Integer commentType;

    private String commentString;


    private CommentType(Integer commentType, String commentString) {
        this.commentType = commentType;
        this.commentString = commentString;
    }

    public static CommentType getCommentString(int type){
        for(CommentType commentType : CommentType.values()){
            if(commentType.getCommentType().intValue() == type){
                return commentType;
            }
        }
        return null;
    }
}
